package com.ysd.lis.controller.cri;


import com.ysd.common.Result;
import com.ysd.lis.controller.pub.BaseController;
import com.ysd.lis.entity.cri.CriWarningConfig;
import com.ysd.lis.service.cri.CriWarningConfigService;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

/**
 * <p>
 * 前端控制器
 * </p>
 *
 * @author wh
 * @since 2025-02-17
 */
@RestController
@RequestMapping("/lis/cri/warningConfig")
public class CriWarningConfigController extends BaseController {

    @Autowired
    private CriWarningConfigService criWarningConfigService;

    @ApiOperation("新增或修改岗位信息")
    @PostMapping("/saveOrUpdateConfig")
    public Result saveOrUpdateConfig(@RequestBody CriWarningConfig criWarningConfig) {
        return criWarningConfigService.saveOrUpdateConfig(criWarningConfig);
    }
    @ApiOperation("根据mac查询数据")
    @GetMapping("/getInfoByMac")
    public Result getInfoByMac(String macUrl) {
        return criWarningConfigService.getInfoByMac(macUrl);
    }
}
